﻿using System.Collections;
using System.Collections.Generic;
using System.Xml.Serialization;
using UnityEngine;

public class MusicData 
{
    [XmlAttribute]
    public bool soundBk;
    [XmlAttribute]
    public bool soundEffect;
    [XmlAttribute]
    public float volume;

    public void Save()
    {
        XmlDataMgr.Instance.SaveData(this, "musicData");
    }

    public void SetSoundEffect(bool value)
    {
        this.soundEffect = value;
        Save();
    }

    public void SetVolume(float value)
    {
        this.volume = value;
        Save();
    }
}
